#!/usr/local/bin/pythonw
# -*- coding: utf-8 -*-

class Corpus_manager :
  def __init__(self, _path_dir_corpus, _path_file_index) :
    self.path_dir_corpus = _path_dir_corpus
    self.path_file_index = _path_file_index

  def __repr__(self) :
    return "[%s %s]"%(self.path_dir_corpus,self.path_file_index)


  def get_index(self) :
    #index = {}
    #index[(info1,info2,...)] = path_file
    #return index
    pass

  def filter_index_time(self, index, time_criterion) :
    #time_criterion = (date_start,date_end)
    #new_index = {}
    # ... profit ...
    #return index
    pass

  def filter_index_domain(self, index, domain_criterion) :
    #domain_criterion = 'domain'
    #new_index = {}
    # ... profit ...
    #return index
    pass

  def union_index(self, index1, index2) :
    pass

  def intersection_index(self, index1, index2) :
    pass

#    try :
#      content = open(path).read()
#      self.index = self.content2index(content)
#    except Exception, e :
#      self.index = self.dir2index(_dir)
